package com.yeren.service.impl;

import java.util.List;

import com.yeren.dao.WeixinUserInfoDao;
import com.yeren.dao.impl.WeixinUserInfoDaoImpl;
import com.yeren.entity.WeixinUserInfo;
import com.yeren.service.WeixinUserInfoService;
import com.yeren.utils.PageBean;

/**
 * liubiao
 */
public class WeixinUserInfoServiceImpl implements WeixinUserInfoService{
	WeixinUserInfoDao weixinUserInfoDao=new WeixinUserInfoDaoImpl();
	
	public int save(WeixinUserInfo weixinUserInfo) {
		int save=weixinUserInfoDao.save(weixinUserInfo);
		return save;
	}

	public int delete(String openId) {
		int delete=weixinUserInfoDao.delete(openId);
		return delete;
	}

	public boolean isExitOpenId(String openId) {
		boolean isExitOpenId=weixinUserInfoDao.isExitOpenId(openId);
		return isExitOpenId;
	}

	public int update(WeixinUserInfo weixinUserInfo) {
		int update=weixinUserInfoDao.update(weixinUserInfo);
		return update;
	}

	public WeixinUserInfo findByOpenId(String openId) {
		WeixinUserInfo weixinUserInfo=weixinUserInfoDao.findByOpenId(openId);
		return weixinUserInfo;
	}

	public List<WeixinUserInfo> findAll(WeixinUserInfo weixinUserInfo,
			PageBean pageBean) {
		List<WeixinUserInfo> list=weixinUserInfoDao.findAll(weixinUserInfo, pageBean);
		return list;
	}

	public int getSum() {
		int getSum=weixinUserInfoDao.getSum();
		return getSum;
	}
	
}
